package com.example.test_20210615_yzm;

import java.util.*;

public class YzmTest {

    public static String YzmInfo(){
        StringBuilder build = new StringBuilder();
        build.append("0123456789");
        build.append("abcdefghijklmnopqrstuvwxyz");
        build.append(build.toString().toUpperCase());
        char[] chars = build.toString().toCharArray();

        Random random = new Random();

        StringBuilder builder = new StringBuilder();
        for (int i = 0 ; i < 5; i++){
            builder.append(chars[random.nextInt(chars.length)]);
        }
        System.out.println(build.toString());
        return builder.toString();
    }

    public static void main(String[] args) {
//        String yzmInfo = YzmInfo();
//        System.out.println("------------------------------------");
//        System.out.println("yzm="+yzmInfo);
//        System.out.println("------------------------------------");

        List<String> list = new ArrayList<>();
        list.add("a");
        list.add("b");
        list.add("c");
        list.removeIf("a"::equals);
//        for (String s:list) {
//            list.remove("a");
//        }
        Set<String> set = new HashSet<>();
        set.add("a");
        set.add("b");
        set.add("c");
        System.out.println("list="+list);
    }
}
